
import unittest                                   #Python单元测试框架
from configparser import ConfigParser             #读取配置库
from selenium import webdriver                    #导入selenium库
from appium import webdriver                      #导入appium库

from config import appium_config


class AddFriendsWithAppium(unittest.TestCase):
    """
        TestCase: xxxxx
        Description: xxxxx
        """

    # @classmethod,在此类中只进行一次初始化和清理工作
    @classmethod
    def setUpClass(self):
        self.driver = appium_config.appium_start()
        self.cfg = ConfigParser()
        self.cfg.read('config.ini')

    def test_initial(self):
        self.cfg.get('login', 'user')
        # self.driver.find_element_by_id(resource - id).click()
        # self.driver.find_element_by_id(resource - id).send_keys(u'测试数据')

    @classmethod
    def tearDownClass(self):
        self.driver.quit()